package com.yulinlin.jdbc.mysql;

public class MysqlFunctionEnum {

    //总数
    public static String count = "count(#{columnName})";

    //和
    public static String  sum="sum(#{columnName})";

    //平均
    public static String  avg = "avg(#{columnName})";

    public static String   min="min(#{columnName})";

    public static String  max="max(#{columnName})";

    //小时
    public static String  hour=" DATE_FORMAT('#{columnName}','%Y-%m-%d %H')";

    //天
    public static String  day=" DATE_FORMAT('#{columnName}','%Y-%m-%d')";

    //月
    public static String  month=" DATE_FORMAT('#{columnName}','%Y-%m')";

    //年
    public static String  year=" DATE_FORMAT('#{columnName}','%Y')";


}
